<#assign ctx=request.contextPath />
<#import '${ctx}/sys/include/head.html' as d />
<#import '${ctx}/sys/include/info.html' as i />
<!DOCTYPE html>
<html>
<head><@d.head title="数据源信息" />
  <link rel="stylesheet" href="${ctx}/resource/css/dtree.css">
  <link rel="stylesheet" href="${ctx}/resource/css/font/dtreefont.css">
</head>
<@i.add url="${ctx}/biz/data/dw/add">
<form class="layui-form">
	<div class="layui-form-item">
		<label class="layui-form-label">名称</label>
		<div class="layui-input-block">
			<input type="text" name="name" placeholder="数据源名" autocomplete="off"
				class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">仓库类型</label>
		<div class="layui-input-block">
			<input type="radio" name="type" class="layui-input" title="Elasticsearch"/>
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">地址</label>
		<div class="layui-input-block">
			<input type="text" name="host" placeholder="地址" autocomplete="off" lay-verify="ip"
				class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">端口</label>
		<div class="layui-input-block">
			<input type="text" name="port" placeholder="端口" autocomplete="off" lay-verify="number"
				class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">说明</label>
		<div class="layui-input-block">
			<input type="text" name="comment" placeholder="说明" autocomplete="off"
				class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<div class="layui-input-block">
			<button class="layui-btn" lay-submit lay-filter="save">保存</button>
			<a class="layui-btn layui-btn-primary" id="cls_btn">关闭</a>
		</div>
	</div>
</form>
<script type="text/javascript">
var verifies = {
		ip: [
			/^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])$/
			,'IP地址不符合规则'
			]
		};
</script>
</@i.add>
</html>
